package com.zuipin.service;

import java.math.BigDecimal;
import java.util.List;

import com.zuipin.entity.BalanceRecord;
import com.zuipin.enums.BalanceType;
import com.zuipin.framework.exception.CustomException;
import com.zuipin.util.Pagination;

/**
 * @ClassName: IBalanceRecordService
 * @author wuyicheng
 * @time 2017年3月27日下午3:59:53
 */
public interface IBalanceRecordService {
	
	public BalanceRecord findById(Long id);
	
	public List<BalanceRecord> findList(Long memberId);
	
	public void insert(BalanceRecord balanceRecord);
	
	public void update(BalanceRecord balanceRecord);
	
	public void deleteById(Long id);
	
	public void updateBalance(Long memberId, Long sysId, Long createId, Long updateId, BigDecimal alterMoney, BalanceType balanceType, String remark, String describe,
			String oddNumbers, int isBuy) throws CustomException;
	
	/** 
	 *
	 * @Title: findListByPage 
	 * @author: wuyicheng
	 * @date: 2017年4月25日下午2:10:53 
	 * @param balanceRecord
	 * @param page
	 * @return
	 * @return: List<BalanceRecord>
	 * @throws 
	 */
	public List<BalanceRecord> findListByPage(BalanceRecord balanceRecord, Pagination page);
	
	/**
	 * 通过会员ID获取当前余额
	 * @param memberId
	 * @return
	 */
	public BigDecimal getCurrentBalance(Long memberId, Long sysId);
	
	/**
	 *  查询根据单号查询充值支付状态
	  *  @Title: queryPayStatusByOddNumbers
	  * @author joy.zhang
	  * @date 2017年8月14日 上午11:30:26
	  * @param sysId
	  * @param oddNumbers
	  * @return
	  * @return boolean
	 */
	public boolean queryPayStatusByOddNumbers(Long sysId, String oddNumbers);
	
}
